// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3) 
// Source File Name:   CMURLButton.java

package com.boci.common.ui.control;

import java.awt.Color;
import java.awt.Insets;
import javax.swing.*;

public class CMURLButton extends JButton
{

    public CMURLButton()
    {
        this(null, null);
    }

    public CMURLButton(String text)
    {
        this(text, null);
    }

    public CMURLButton(Action a)
    {
        this();
        setAction(a);
    }

    public CMURLButton(Icon icon)
    {
        this(null, icon);
    }

    public CMURLButton(String text, Icon icon)
    {
        super(text, icon);
        setContentAreaFilled(false);
        setForeground(Color.BLUE);
        setBorderPainted(false);
        setMargin(new Insets(0, 0, 0, 0));
        setHorizontalAlignment(0);
    }

    public void setEnabled(boolean pEnable)
    {
        super.setEnabled(pEnable);
        if(!pEnable)
            setForeground(Color.GRAY);
        else
            setForeground(Color.BLUE);
    }

    public void setText(String pText)
    {
        super.setText(pText);
    }
}
